package com.liu.spike.config;

import com.liu.spike.common.KafkaTopic;
import org.apache.kafka.clients.admin.NewTopic;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @className: com.liu.spike.config.KafkaConfig
 * @description: TODO
 * @author: liu
 * @create: 2022-05-02 14:22
 */

@Configuration
public class KafkaConfig {

    @Bean
    public NewTopic spikeTopic(){
        return new NewTopic(KafkaTopic.SPIKE_TOPIC,3, (short) 1);
    }

}
